/**
 * 
 */
package com.wubo.sec.model;

import java.util.Date;

import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Lob;
import javax.persistence.Table;

import com.wubo.sec.log.ILog;

/**
 * @author wubo
 * @CreateDate 2010-7-29
 * @version 1.0.01
 */
@Entity
@Table(name="SEC_ERRORLOG")
public class ErrorLog implements ILog {
	@Id
	@GeneratedValue(strategy=GenerationType.AUTO)
	private long id;
	
	@Column(length=100)
	private String type; //错误类型
	
	private String message; //错误消息
	
	@Column(name="occur_time")
	private Date occurTime; //发生时间
	
	@Lob
	@Basic(fetch=FetchType.EAGER)
	private String detail; //详细（异常堆栈信息）

	public long getId() {
		return id;
	}

	public void setId(long id) {
		this.id = id;
	}

	public String getMessage() {
		return message;
	}

	public void setMessage(String message) {
		this.message = message;
	}

	public Date getOccurTime() {
		return occurTime;
	}

	public void setOccurTime(Date occurTime) {
		this.occurTime = occurTime;
	}

	public String getDetail() {
		return detail;
	}

	public void setDetail(String detail) {
		this.detail = detail;
	}

	public String getType() {
		return type;
	}

	public void setType(String type) {
		this.type = type;
	}
}
